
import MainPage from '../views/mainPage.vue'
export const supplayMenu = [
    {
        path: '/',
        component: MainPage,
        redirect: '/dashboard',
        meta: { hidden: false, title: '报表管理', 'icon': '' },
        children: [
            {
                path: 'dashboard',
                component: () => import('@/views/dashboard/index.vue'),
                name: 'Dashboard',
                meta: {
                    title: '报表管理',
                    icon: 'dashboard'
                }
            }
        ]

    },

    {
        path: '/moneyAdmin',
        component: MainPage,
        name: 'moneyAdmin',
        meta: { hidden: false, title: '财务管理', 'icon': '' },
        children: [
            {
                path: '/detail',
                name: 'detail',
                component: () => import('../views/moneyAdmin/detail.vue'),
                meta: {
                    title: '财务明细',
                    icon: '',
                    hidden: false
                }
            },
            {
                path: '/approval',
                name: 'approval',
                component: () => import('../views/moneyAdmin/approval.vue'),
                meta: {
                    title: '提现审批',
                    icon: '',
                    hidden: false
                }
            }
        ]
    },
    {
        path: '/product',
        component: MainPage,
        redirect: '/product/index',
        meta: {
            title: '商品管理',
            icon: ''
        },
        children: [
            {
                path: '/product/index',
                component: () => import('@/views/product/index.vue'),
                name: 'productindex',
                meta: {
                    title: '商品管理',
                    icon: 'guide',

                }
            },
            {
                path: '/product/edit/:id',
                component: () => import('@/views/product/edit.vue'),
                name: 'productEdit',
                meta: {
                    title: '编辑商品',
                    icon: 'guide',
                    hidden: true
                }
            }
        ]
    },
    
        {
            path: '*',
            name: 'error',
            component: () => import('../views/404.vue')
          }
    

]



export const adminMenu = [

    {
        path: '/',
        component: MainPage,
        redirect: '/dashboard',
        meta: { hidden: false, title: '报表管理', 'icon': '' },
        children: [
            {
                path: 'dashboard',
                component: () => import('@/views/dashboard/index.vue'),
                name: 'Dashboard',
                meta: {
                    title: '报表管理',
                    icon: 'dashboard'
                }
            }
        ]

    },
    {
        path: '/product',
        component: MainPage,
        redirect: '/product/index',
        meta: {
            title: '商品管理',
            icon: ''
        },
        children: [
            {
                path: '/product/index',
                component: () => import('@/views/product/index.vue'),
                name: 'productindex',
                meta: {
                    title: '商品管理',
                    icon: 'guide',

                }
            },
            {
                path: '/product/edit/:id',
                component: () => import('@/views/product/edit.vue'),
                name: 'productEdit',
                meta: {
                    title: '编辑商品',
                    icon: 'guide',
                    hidden: true
                }
            }
        ]
    },
    {
        path: '/moneyAdmin',
        component: MainPage,
        meta: { hidden: false, title: '财务管理', 'icon': '' },
        children: [
            {
                path: '/detail',
                name: 'detail',
                component: () => import('../views/moneyAdmin/detail.vue'),
                meta: {
                    title: '财务明细',
                    icon: '',
                    hidden: false
                }
            },
            {
                path: '/approval',
                name: 'approval',
                component: () => import('../views/moneyAdmin/approval.vue'),
                meta: {
                    title: '提现审批',
                    icon: '',
                    hidden: false
                }
            }
        ]
    },
    {
        path: '/list',
        component: MainPage,
        redirect: '/list/index',
        meta: {
            title: '综合list'
        },
        children: [
            {
                path: '/index',
                component: () => import('@/views/list/index.vue'),
                name: 'indexlist',
                meta: {
                    title: 'indexlist',
                    icon: 'edit',
                    activeMenu: '/list/index',
                },

            },
            {
                path: '/create',
                component: () => import('@/views/list/create.vue'),
                name: 'CreateList',
                meta: {
                    title: 'CreateList',
                    icon: 'edit'
                }
            },

            {
                path: '/edit/:id',
                component: () => import('@/views/list/edit.vue'),
                name: 'editList',
                meta: {
                    title: 'editList',
                    icon: 'edit',
                    activeMenu: '/list/index',
                }
            }



        ]
    }

]
